package cn.edu.scau.cmi.ningkehua.simpleFactoryMethod;

public class MeatFactory {
	public static Meat getMeatObj(String option) {
		Meat meat=null;
		if(option.compareTo("pork")==0) {
			meat=new Pork();
		}
		else if(option.compareTo("beef")==0) {
			meat=new Beef();
		}
		else if(option.compareTo("chicken")==0) {
			meat=new Chicken();
		}
		return meat;
	}
}
